package org.rvk.vms.web.controller.common;

import javax.servlet.http.HttpServletRequest;

import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class CommonController {
	
	@RequestMapping(value="/login")
	public String processLogin(HttpServletRequest request){
		return "login";
	}
	
	@RequestMapping(value="/authenticationFailure")
	public String authenticationFailed(ModelMap model) {
		model.addAttribute("ERROR", true);
		return "login";
	}
	
	@RequestMapping(value="/logout")
	public String logout(ModelMap model) {
		model.addAttribute("LOGOUT", true);
		return "login";
	}
	
}
